package com.ruoyi.community.service.impl;

import com.ruoyi.community.domain.HeartActivityDetail;
import com.ruoyi.community.mapper.HeartActivityDetailMapper;
import com.ruoyi.community.service.IHeartActivityService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class HeartActivityServiceImpl implements IHeartActivityService {

    @Autowired
    HeartActivityDetailMapper heartActivityDetailMapper;

    @Override
    public List<HeartActivityDetail> selectHeartActivityDetailList(HeartActivityDetail heartActivityDetail) {
        return heartActivityDetailMapper.selectHeartActivityDetailList(heartActivityDetail);
    }
    @Override
    public List<HeartActivityDetail> selectHeartActivityDetailWxList(HeartActivityDetail heartActivityDetail) {
        return heartActivityDetailMapper.selectHeartActivityDetailWxList(heartActivityDetail);
    }

    @Override
    public int insert(HeartActivityDetail heartActivityDetail) {
        return heartActivityDetailMapper.insert(heartActivityDetail);
    }

    @Override
    public HeartActivityDetail selectHeartActivityDetailById(Long id) {
        return heartActivityDetailMapper.selectByPrimaryKey(id);
    }

    @Override
    public int updateByActivityId(HeartActivityDetail heartActivityDetail) {
        return heartActivityDetailMapper.updateByPrimaryKeySelective(heartActivityDetail);
    }

    @Override
    public long getInitiatorid(Long activityid) {
        return heartActivityDetailMapper.getInitiatorid(activityid);
    }
}
